﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Startup.Shell.Domain.FunctionalityContracts
{
	internal class FunctionalityContractsManager
	{
		private readonly CommandContractBase[] _contracts = new[]
		{
			(CommandContractBase)new NewCommandContract(),
			(CommandContractBase)new LoadCommandContract(),
			(CommandContractBase)new SaveCommandContract(),
			(CommandContractBase)new AddCommandContract(),
		};

		private FunctionalityContractsManager()
		{ }

		private static FunctionalityContractsManager _instance;

		public static IList<CommandContractBase> Contracts
		{
			get
			{
				if (_instance == null)
					_instance = new FunctionalityContractsManager();

				return _instance._contracts;
			}
		}
	}
}
